<template>
  <div id="app">
    <h2>App:{{ $store.state.counter }}</h2>
    <button @click="addNumber">+1</button>
    <button @click="reduceNumber">-1</button>

    <home />
  </div>
</template>

<script>
import Home from "./pages/Home.vue";
export default {
  name: "App",
  components: {
    Home,
  },
  data() {
    return {
      message: "vue devtoolds",
    };
  },
  methods: {
    addNumber() {
      this.$store.commit("increment");
    },
    reduceNumber() {
      this.$store.commit("decrement");
    },
  },
};
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
</style>
